package edu.gatech.cc.concolic.expression;


public abstract class SymbolicConstant implements SymbolicExpression {

	protected final Number value;
	
	public int l;
	public int h;
	public int lr;
	public int hr;
	
	public SymbolicConstant(Number value) {
		this.value = value;
	}
	
	public Number value() {
		return value;
	}
	
	public String toString() {
		return value.toString();
	}

	public int hashCode() {
		int result = 17;
		result = 37 * result + value.hashCode();
		return result;
	}

	public boolean equals(Object o) {
		if (this == o) return true;
		if (o == null || !(getClass().isInstance(o))) return false;

		SymbolicConstant other = (SymbolicConstant) o;

		return value.equals(other.value);
	}
}
